Application 

Inherits from:       
System 

_____________________________________________________
                        current *178*

Type:  
Application 

Constraints:
Not settable.

Description:
The currently active «Application». 

_____________________________________________________
                        front  *178*

Type: 
Window 

Constraints:
Not settable in an inactive «Application», or if the «Window» is not active.

Description:
The frontmost window, which is the first element of the window list in attribute windows; NULL in an inactive «Application». 

_____________________________________________________
                        name  *178*

Type:  string 

Description: 
Appears in the About… menu item of the Apple menu when the «Application» is active.

_____________________________________________________
                        owner  *178*

Type:  null 

Constraints:
Not settable.

_____________________________________________________
                        active?  *179*

Type:  boolean

Constraints:
Not settable on default.

Side effects: 
When set to TRUE, «Application» becomes the value of attribute current, the active? attributes of the active «Window»s and «Menu»s of «Application» are set to TRUE, and the Application Manager is started. When it is set to FALSE, the active? attribute of the active «Window»s and «Menu»s of «Application» are set to FALSE, and the Application Manager is stopped.

_____________________________________________________
                         menu bar   *179*

Type:  ABlock@@

Constraints:
Not settable.

Description:
Menu bar of «Application».

_____________________________________________________
                         resources   *179*

Type:  integer 

Constraints:
Not settable.

Description:
File reference number of resource file of «Application».

_____________________________________________________
                       about method   *179*

Type: 
string

Description:
Name of method called when About… menu item is selected.

Method inputs:
«Application»

_____________________________________________________
                        aevent methods   *180*

Type: 
list

Description:
List of  triplet lists specifying Prograph methods to respond to incoming  Apple Events.  Each triplet list is a list of strings of the form (<Event Class> <Event ID> <method name>).

_____________________________________________________
                       menus    *180*

Type:  list of Menu

Constraints:
Not settable when «Application» is active.

Description:
List of active «Menu»s of «Application». Left to right order in the list corresponds to left to right order in the menu bar.

Warning:
Results are unpredictable if the list of active «Menu»s contains any «Menu» more than once.

_____________________________________________________
                        windows    *180*

Type:  list of Window 

Constraints:
Not settable when «Application» is active.

Description:
Active «Window»s of «Application». Left to right order in the list corresponds to front to back order on screen.

Warning:
Results are unpredictable if the list of active «Window»s contains any «Window» more than once.

_____________________________________________________
  
                     menu lib    *180*

Type:  list of Menu 

Description:
List of «Menu»s of «Application», whether or not they are active. 

_____________________________________________________
                       
window lib    *181*

Type:  list of Window 

Description:
List of «Window»s of «Application», whether or not they are active. 

__________________________________________________________
HINTS AND TIPS: SUBCLASSING APPLICATION

You can create a subclass of Application and install it as the current application. To do so, first create the subclass of Application (called MyApp, for example) in the Classes window.  Create a persistent in the Persistents window and double-click it to open a Value window. From the diplayed list of classes, select the MyApp class.  This creates a MyApp instance.  From the Apple menu select Enter Editor.  This opens the Application Editor dialog with the Install button enabled.  Click the Install button to make the instance of MyApp the current application.

---------------------------------------------------------